{extend name="layout:home" /}
{block name="container"}
<div class="layui-tab layui-tab-card">
    {include file="layout/admin_items" /}
    <div class="layui-tab-content page-tab-content">
        <table class="layui-table lay-even">
            <colgroup>
                <col width="150">
                <col width="200">
                <col width="100">
                <col width="100">
                <col width="100">
                <col>
            </colgroup>
            <thead>
                <tr>
                    <th>{$Think.lang.cases_title}</th>
                    <th>{$Think.lang.cases_order}</th>
                    <th>{$Think.lang.cases_new_ok}</th>
                    <th>{$Think.lang.cases_top_ok}</th>
                    <th>{$Think.lang.cases_com_ok}</th>
                    <th>{$Think.lang.ds_operation}</th>
                </tr>
            </thead>
            <tbody>
            {volist name="cases_list" id="cases"}
            <tr>
                <td>{$cases.cases_title}</td>
                <td><span title="{:lang('ds_editable')}" ajax_branch='cases' datatype="number" fieldid="{$cases.cases_id}" fieldname="cases_order" ds_type="inline_edit" class="editable">{$cases.cases_order}</span></td>
                <td>
                    <a href="javascript:dsLayerConfirm('{:url('Cases/setCases',['cases_type'=>'cases_new_ok','cases_id'=>$cases.cases_id])}','{$Think.lang.ds_confirm_update}')">
                        {if condition="$cases.cases_new_ok eq 1"}<i class="layui-icon">&#xe605;</i>{else}<i class="layui-icon">&#x1006;</i>{/if}
                    </a>
                </td>
                <td>
                    <a href="javascript:dsLayerConfirm('{:url('Cases/setCases',['cases_type'=>'cases_top_ok','cases_id'=>$cases.cases_id])}','{$Think.lang.ds_confirm_update}')">
                        {if condition="$cases.cases_top_ok eq 1"}<i class="layui-icon">&#xe605;</i>{else}<i class="layui-icon">&#x1006;</i>{/if}
                    </a>
                </td>
                <td>
                    <a href="javascript:dsLayerConfirm('{:url('Cases/setCases',['cases_type'=>'cases_com_ok','cases_id'=>$cases.cases_id])}','{$Think.lang.ds_confirm_update}')">
                        {if condition="$cases.cases_com_ok eq 1"}<i class="layui-icon">&#xe605;</i>{else}<i class="layui-icon">&#x1006;</i>{/if}
                    </a>
                </td>
                <td>
                    <a href="{:url('home/Cases/detail',['cases_id'=>$cases.cases_id])}" target="_blank" class="layui-btn layui-btn-primary layui-btn-xs"><i class="layui-icon layui-icon-list"></i>前台查看</a>
                    <a href="{:url('Cases/edit',['cases_id'=>$cases.cases_id])}" class="layui-btn layui-btn-xs"><i class="layui-icon layui-icon-edit"></i>{$Think.lang.ds_edit}</a>
                    <a href="javascript:dsLayerConfirm('{:url('Cases/del',['cases_id'=>$cases.cases_id])}','{$Think.lang.ds_confirm_cancel}')" class="layui-btn layui-btn-danger layui-btn-xs"><i class="layui-icon layui-icon-delete"></i>{$Think.lang.ds_del}</a>
                </td>
            </tr>
            {/volist}
        </tbody>
        </table>
        {$show_page|raw}
    </div>
</div>
<script type="text/javascript" src="{$Think.ADMIN_SITE_ROOT}/js/jquery.edit.js"></script>
{/block}